// 导入 ejs 模块
const ejs = require("ejs");
const fs = require("fs");
const path = require("path");

// 读取模板内容
const data = fs.readFileSync(path.resolve(__dirname, "template.html"));
// console.log(data.toString());

// 渲染内容
let china = "中国";
let rlt = ejs.render(data.toString(), { china: china });
console.log(rlt);
